babyishfandomcom-20200214-history
FUSE
| latest preview version = | latest preview date = | programming language = C | operating system = Unix Unix-like | genre = File system driver | license = GPL for kernel part, LGPL for Libfuse, Simplified BSD on FreeBSD, ISC license on OpenBSD | website = }} Filesystem in Userspace (FUSE) is a software interface for Unix and Unix-like computer operating systems that lets non-privileged users create their own file systems without editing kernel code. This is achieved by running file system code in user space while the FUSE module provides only a "bridge" to the actual kernel interfaces. FUSE is available for Linux, FreeBSD, OpenBSD, NetBSD (as puffs), OpenSolaris, Minix 3, Android and macOS. FUSE is free software originally released under the terms of the GNU General Public License and the GNU Lesser General Public License. History The FUSE system was originally part of AVFS (A Virtual Filesystem), a filesystem implementation heavily influenced by the translator concept of the GNU Hurd. FUSE was originally released under the terms of the GNU General Public License and the GNU Lesser General Public License, later also reimplemented as part of the FreeBSD base system and released under the terms of Simplified BSD license. An ISC-licensed re-implementation by Sylvestre Gallon was released in March 2013, and incorporated into OpenBSD in June 2013. FUSE was merged into the mainstream Linux kernel tree in kernel version 2.6.14. Operation and Uses To implement a new file system, a handler program linked to the supplied libfuse library needs to be written. The main purpose of this program is to specify how the file system is to respond to read/write/stat requests. The program is also used to mount the new file system. At the time the file system is mounted, the handler is registered with the kernel. If a user now issues read/write/stat requests for this newly mounted file system, the kernel forwards these IO-requests to the handler and then sends the handler's response back to the user. FUSE is particularly useful for writing virtual file systems. Unlike traditional file systems that essentially work with data on mass storage, virtual filesystems don't actually store data themselves. They act as a view or translation of an existing file system or storage device. In principle, any resource available to a FUSE implementation can be exported as a file system. Example uses *archivemount *CloudStore (formerly, Kosmos filesystem): By mounting via FUSE, existing Linux utilities can interact with CloudStore *EncFS: Encrypted virtual filesystem *ExpanDrive: A commercial filesystem implementing SFTP/FTP/S3/Swift using FUSE *FTPFS *GlusterFS: Clustered Distributed Filesystem having ability to scale up to several petabytes. *GVfs: The virtual filesystem for the GNOME desktop *IPFS: A peer-to-peer distributed file system that seeks to connect all computing devices with the same system of files. *KBFS: A distributed filesystem with end-to-end encryption and a global namespace based on Keybase.io service that uses FUSE to create cryptographically secure file mounts. *Lustre cluster filesystem will use FUSE to allow it to run in userspace, so that a FreeBSD port is possible. However, the ZFS-Linux port of Lustre will be running ZFS's DMU (Data Management Unit) in userspace. *Linear Tape File System: Allows files stored on magnetic tape to be accessed in a similar fashion to those on disk or removable flash drives. *MinFS: MinFS is a fuse driver for Amazon S3 compatible object storage server. MinFS lets you mount a remote bucket (from a S3 compatible object store), as if it were a local directory *MooseFS: An open source distributed fault-tolerant file system available on every OS with FUSE implementation (Linux, FreeBSD, NetBSD, OpenSolaris, OS X), able to store petabytes of data spread over several servers visible as one resource. *NTFS-3G and Captive NTFS, allowing access to NTFS filesystems *s3fs: mount an S3 bucket as if it were a local file system *Sector File System: Sector is a distributed file system designed for large amount of commodity computers. Sector uses FUSE to provide a mountable local file system interface *SSHFS: Provides access to a remote filesystem through SSH *Transmit: A commercial FTP client that also adds the ability to mount WebDAV, SFTP, FTP and Amazon S3 servers as disks in Finder, via MacFUSE. *WebDrive: A commercial filesystem implementing WebDAV, SFTP, FTP, FTPS and Amazon S3 *WikipediaFS: View and edit Wikipedia articles as if they were real files *Wuala: A multi-platform, Java-based fully OS integrated distributed file system. Using FUSE, MacFUSE and Callback File System respectively for file system integration, in addition to a Java-based app accessible from any Java-enabled web browser (service discontinued in 2015). *SPFS a file system for Spectrum Protect, designed to mount the backup server filespace anywhere on your server, and use the features included from the backup server ( encryption, de-duplication, compression, filtrering etc). This is a WORM file system Komponènts * fuse: * libfuse2: This package contains the shared library. Päkeijs Kloniŋ sōrs $ git clone git://git.code.sf.net/p/fuse/fuse fuse-fuse Cloning into 'fuse-fuse'... remote: Counting objects: 8676, done. remote: Compressing objects: 100% (2389/2389), done. remote: Total 8676 (delta 6975), reused 7733 (delta 6232) Receiving objects: 100% (8676/8676), 1.85 MiB | 391.00 KiB/s, done. Resolving deltas: 100% (6975/6975), done. Checking connectivity... done. $ cd fuse-fuse $ git remote add babycaseny git@github.com:babycaseny/fuse-fuse.git $ git push -u babycaseny master Counting objects: 7783, done. Delta compression using up to 8 threads. Compressing objects: 100% (1618/1618), done. Writing objects: 100% (7783/7783), 1.74 MiB | 819.00 KiB/s, done. Total 7783 (delta 6233), reused 7614 (delta 6114) To git@github.com:babycaseny/fuse-fuse.git * branch master -> master Branch master set up to track remote branch master from babycaseny by rebasing. Jenereitiŋ ./configure $ ./makeconf.sh Running libtoolize... Running autoreconf... libtoolize: putting auxiliary files in `.'. libtoolize: copying file `./ltmain.sh' libtoolize: putting macros in AC_CONFIG_MACRO_DIR, `m4'. libtoolize: copying file `m4/libtool.m4' libtoolize: copying file `m4/ltoptions.m4' libtoolize: copying file `m4/ltsugar.m4' libtoolize: copying file `m4/ltversion.m4' libtoolize: copying file `m4/lt~obsolete.m4' configure.ac:9: installing './compile' configure.ac:4: installing './config.guess' configure.ac:4: installing './config.sub' configure.ac:5: installing './install-sh' configure.ac:5: installing './missing' Makefile.am: installing './INSTALL' example/Makefile.am: installing './depcomp' To compile run './configure', and then 'make'. Jenereitiŋ Makefile $ ./configure checking build system type... x86_64-unknown-linux-gnu checking host system type... x86_64-unknown-linux-gnu checking target system type... x86_64-unknown-linux-gnu checking for a BSD-compatible install... /usr/bin/install -c checking whether build environment is sane... yes checking for a thread-safe mkdir -p... /bin/mkdir -p checking for gawk... no checking for mawk... mawk checking whether make sets $(MAKE)... yes checking whether make supports nested variables... yes checking whether make supports nested variables... (cached) yes checking how to print strings... printf checking for style of include used by make... GNU checking for gcc... gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... no checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether gcc accepts -g... yes checking for gcc option to accept ISO C89... none needed checking whether gcc understands -c and -o together... yes checking dependency style of gcc... gcc3 checking for a sed that does not truncate output... /bin/sed checking for grep that handles long lines and -e... /bin/grep checking for egrep... /bin/grep -E checking for fgrep... /bin/grep -F checking for ld used by gcc... /usr/bin/ld checking if the linker (/usr/bin/ld) is GNU ld... yes checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B checking the name lister (/usr/bin/nm -B) interface... BSD nm checking whether ln -s works... yes checking the maximum length of command line arguments... 1572864 checking whether the shell understands some XSI constructs... yes checking whether the shell understands "+="... yes checking how to convert x86_64-unknown-linux-gnu file names to x86_64-unknown-linux-gnu format... func_convert_file_noop checking how to convert x86_64-unknown-linux-gnu file names to toolchain format... func_convert_file_noop checking for /usr/bin/ld option to reload object files... -r checking for objdump... objdump checking how to recognize dependent libraries... pass_all checking for dlltool... no checking how to associate runtime and link libraries... printf %s\n checking for ar... ar checking for archiver @FILE support... @ checking for strip... strip checking for ranlib... ranlib checking command to parse /usr/bin/nm -B output from gcc object... ok checking for sysroot... no checking for mt... mt checking if mt is a manifest tool... no checking how to run the C preprocessor... gcc -E checking for ANSI C header files... yes checking for sys/types.h... yes checking for sys/stat.h... yes checking for stdlib.h... yes checking for string.h... yes checking for memory.h... yes checking for strings.h... yes checking for inttypes.h... yes checking for stdint.h... yes checking for unistd.h... yes checking for dlfcn.h... yes checking for objdir... .libs checking if gcc supports -fno-rtti -fno-exceptions... no checking for gcc option to produce PIC... -fPIC -DPIC checking if gcc PIC flag -fPIC -DPIC works... yes checking if gcc static flag -static works... yes checking if gcc supports -c -o file.o... yes checking if gcc supports -c -o file.o... (cached) yes checking whether the gcc linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes checking whether -lc should be explicitly linked in... no checking dynamic linker characteristics... GNU/Linux ld.so checking how to hardcode library paths into programs... immediate checking whether stripping libraries is possible... yes checking if libtool supports shared libraries... yes checking whether to build shared libraries... yes checking whether to build static libraries... yes checking for gcc option to accept ISO C99... -std=gnu99 checking for gcc -std=gnu99 option to accept ISO Standard C... (cached) -std=gnu99 checking for special C compiler options needed for large files... no checking for _FILE_OFFSET_BITS value needed for large files... no checking for fork... yes checking for setxattr... yes checking for fdatasync... yes checking for splice... yes checking for vmsplice... yes checking for utimensat... yes checking for pipe2... yes checking for posix_fallocate... yes checking for fstatat... yes checking for openat... yes checking for readlinkat... yes checking for struct stat.st_atim... yes checking for struct stat.st_atimespec... no checking for library containing dlopen... -ldl checking for library containing clock_gettime... none required checking for ulockmgr_op in -lulockmgr... no checking for ld used by gcc -std=gnu99... /usr/bin/ld -m elf_x86_64 checking if the linker (/usr/bin/ld -m elf_x86_64) is GNU ld... yes checking for shared library run path origin... done checking for iconv... yes checking for working iconv... yes checking for iconv declaration... extern size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft); configure: MOUNT_FUSE_PATH env var not set, using default /sbin configure: UDEV_RULES_PATH env var not set, using default /etc/udev/rules.d configure: INIT_D_PATH env var not set, using default /etc/init.d checking if umount supports --fake --no-canonicalize... yes checking that generated files are newer than configure... done configure: creating ./config.status config.status: creating fuse3.pc config.status: creating Makefile config.status: creating lib/Makefile config.status: creating util/Makefile config.status: creating example/Makefile config.status: creating include/Makefile config.status: creating doc/Makefile config.status: creating include/config.h config.status: executing depfiles commands config.status: executing libtool commands make $ make Making all in include make1: Entering directory `/home/tom/Development/fuse-fuse/include' make all-am make2: Entering directory `/home/tom/Development/fuse-fuse/include' make2: Leaving directory `/home/tom/Development/fuse-fuse/include' make1: Leaving directory `/home/tom/Development/fuse-fuse/include' Making all in lib make1: Entering directory `/home/tom/Development/fuse-fuse/lib' CC fuse.lo CC fuse_loop.lo CC fuse_loop_mt.lo CC fuse_lowlevel.lo CC fuse_mt.lo CC fuse_opt.lo CC fuse_session.lo CC fuse_signals.lo CC buffer.lo CC cuse_lowlevel.lo CC helper.lo helper.c: In function ‘fuse_daemonize’: helper.c:199:3: warning: ignoring return value of ‘chdir’, declared with attribute warn_unused_result -Wunused-result (void) chdir("/"); ^ helper.c:210:3: warning: ignoring return value of ‘chdir’, declared with attribute warn_unused_result -Wunused-result (void) chdir("/"); ^ CC modules/subdir.lo CC modules/iconv.lo CC mount.lo CC mount_util.lo mount_util.c: In function ‘mtab_needs_update’: mount_util.c:63:12: warning: ignoring return value of ‘setreuid’, declared with attribute warn_unused_result -Wunused-result setreuid(0, -1); ^ mount_util.c:68:12: warning: ignoring return value of ‘setreuid’, declared with attribute warn_unused_result -Wunused-result setreuid(ruid, -1); ^ mount_util.c: In function ‘add_mount’: mount_util.c:101:9: warning: ignoring return value of ‘setuid’, declared with attribute warn_unused_result -Wunused-result setuid(geteuid()); ^ mount_util.c: In function ‘exec_umount’: mount_util.c:152:9: warning: ignoring return value of ‘setuid’, declared with attribute warn_unused_result -Wunused-result setuid(geteuid()); ^ mount_util.c: In function ‘remove_mount’: mount_util.c:211:9: warning: ignoring return value of ‘setuid’, declared with attribute warn_unused_result -Wunused-result setuid(geteuid()); ^ CCLD libfuse3.la make1: Leaving directory `/home/tom/Development/fuse-fuse/lib' Making all in util make1: Entering directory `/home/tom/Development/fuse-fuse/util' make all-am make2: Entering directory `/home/tom/Development/fuse-fuse/util' CC fusermount-fusermount.o CC fusermount-mount_util.o mount_util.c: In function ‘mtab_needs_update’: mount_util.c:63:12: warning: ignoring return value of ‘setreuid’, declared with attribute warn_unused_result -Wunused-result setreuid(0, -1); ^ mount_util.c:68:12: warning: ignoring return value of ‘setreuid’, declared with attribute warn_unused_result -Wunused-result setreuid(ruid, -1); ^ mount_util.c: In function ‘add_mount’: mount_util.c:101:9: warning: ignoring return value of ‘setuid’, declared with attribute warn_unused_result -Wunused-result setuid(geteuid()); ^ mount_util.c: In function ‘exec_umount’: mount_util.c:152:9: warning: ignoring return value of ‘setuid’, declared with attribute warn_unused_result -Wunused-result setuid(geteuid()); ^ mount_util.c: In function ‘remove_mount’: mount_util.c:211:9: warning: ignoring return value of ‘setuid’, declared with attribute warn_unused_result -Wunused-result setuid(geteuid()); ^ CCLD fusermount CC mount.fuse.o CCLD mount.fuse make2: Leaving directory `/home/tom/Development/fuse-fuse/util' make1: Leaving directory `/home/tom/Development/fuse-fuse/util' Making all in example make1: Entering directory `/home/tom/Development/fuse-fuse/example' CC fusexmp.o CCLD fusexmp CC fusexmp_fh.o CCLD fusexmp_fh CC null.o CCLD null CC hello.o CCLD hello CC hello_ll.o CCLD hello_ll CC fioc.o CCLD fioc CC fioclient-fioclient.o CCLD fioclient CC fsel.o CCLD fsel CC fselclient-fselclient.o CCLD fselclient CC cusexmp.o CCLD cusexmp CC fuse_lo-plus.o CCLD fuse_lo-plus make1: Leaving directory `/home/tom/Development/fuse-fuse/example' Making all in doc make1: Entering directory `/home/tom/Development/fuse-fuse/doc' make1: Nothing to be done for `all'. make1: Leaving directory `/home/tom/Development/fuse-fuse/doc' make1: Entering directory `/home/tom/Development/fuse-fuse' make1: Nothing to be done for `all-am'. make1: Leaving directory `/home/tom/Development/fuse-fuse' make install $ sudo -H make install Making install in include make1: Entering directory `/home/tom/Development/fuse-fuse/include' make2: Entering directory `/home/tom/Development/fuse-fuse/include' make2: Nothing to be done for `install-exec-am'. /bin/mkdir -p '/usr/local/include/fuse3' /usr/bin/install -c -m 644 fuse.h fuse_common.h fuse_lowlevel.h fuse_opt.h cuse_lowlevel.h '/usr/local/include/fuse3' make2: Leaving directory `/home/tom/Development/fuse-fuse/include' make1: Leaving directory `/home/tom/Development/fuse-fuse/include' Making install in lib make1: Entering directory `/home/tom/Development/fuse-fuse/lib' make2: Entering directory `/home/tom/Development/fuse-fuse/lib' /bin/mkdir -p '/usr/local/lib' /bin/bash ../libtool --mode=install /usr/bin/install -c libfuse3.la '/usr/local/lib' libtool: install: /usr/bin/install -c .libs/libfuse3.so.0.0.0 /usr/local/lib/libfuse3.so.0.0.0 libtool: install: (cd /usr/local/lib && { ln -s -f libfuse3.so.0.0.0 libfuse3.so.0 || { rm -f libfuse3.so.0 && ln -s libfuse3.so.0.0.0 libfuse3.so.0; }; }) libtool: install: (cd /usr/local/lib && { ln -s -f libfuse3.so.0.0.0 libfuse3.so || { rm -f libfuse3.so && ln -s libfuse3.so.0.0.0 libfuse3.so; }; }) libtool: install: /usr/bin/install -c .libs/libfuse3.lai /usr/local/lib/libfuse3.la libtool: install: /usr/bin/install -c .libs/libfuse3.a /usr/local/lib/libfuse3.a libtool: install: chmod 644 /usr/local/lib/libfuse3.a libtool: install: ranlib /usr/local/lib/libfuse3.a libtool: finish: PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/sbin" ldconfig -n /usr/local/lib ---------------------------------------------------------------------- Libraries have been installed in: /usr/local/lib If you ever happen to want to link against installed libraries in a given directory, LIBDIR, you must either use libtool, and specify the full pathname of the library, or use the `-LLIBDIR' flag during linking and do at least one of the following: - add LIBDIR to the `LD_LIBRARY_PATH' environment variable during execution - add LIBDIR to the `LD_RUN_PATH' environment variable during linking - use the `-Wl,-rpath -Wl,LIBDIR' linker flag - have your system administrator add LIBDIR to `/etc/ld.so.conf' See any operating system documentation about shared libraries for more information, such as the ld(1) and ld.so(8) manual pages. ---------------------------------------------------------------------- make2: Nothing to be done for `install-data-am'. make2: Leaving directory `/home/tom/Development/fuse-fuse/lib' make1: Leaving directory `/home/tom/Development/fuse-fuse/lib' Making install in util make1: Entering directory `/home/tom/Development/fuse-fuse/util' make install-am make2: Entering directory `/home/tom/Development/fuse-fuse/util' make3: Entering directory `/home/tom/Development/fuse-fuse/util' /bin/mkdir -p '/usr/local/bin' /bin/bash ../libtool --mode=install /usr/bin/install -c fusermount '/usr/local/bin' libtool: install: /usr/bin/install -c fusermount /usr/local/bin/fusermount /bin/mkdir -p /sbin /usr/bin/install -c ./mount.fuse /sbin/mount.fuse /bin/mkdir -p /etc/init.d /usr/bin/install -c ./init_script /etc/init.d/fuse /usr/sbin/update-rc.d fuse start 34 S . start 41 0 6 . || true update-rc.d: warning: stop runlevel arguments (0 6) do not match fuse Default-Stop values (none) Adding system startup for /etc/init.d/fuse ... /etc/rc0.d/S41fuse -> ../init.d/fuse /etc/rc6.d/S41fuse -> ../init.d/fuse /etc/rcS.d/S34fuse -> ../init.d/fuse make install-exec-hook make4: Entering directory `/home/tom/Development/fuse-fuse/util' chmod u+s /usr/local/bin/fusermount make4: Leaving directory `/home/tom/Development/fuse-fuse/util' /bin/mkdir -p /etc/udev/rules.d /usr/bin/install -c -m 644 ./udev.rules /etc/udev/rules.d/99-fuse.rules make3: Leaving directory `/home/tom/Development/fuse-fuse/util' make2: Leaving directory `/home/tom/Development/fuse-fuse/util' make1: Leaving directory `/home/tom/Development/fuse-fuse/util' Making install in example make1: Entering directory `/home/tom/Development/fuse-fuse/example' make2: Entering directory `/home/tom/Development/fuse-fuse/example' make2: Nothing to be done for `install-exec-am'. make2: Nothing to be done for `install-data-am'. make2: Leaving directory `/home/tom/Development/fuse-fuse/example' make1: Leaving directory `/home/tom/Development/fuse-fuse/example' Making install in doc make1: Entering directory `/home/tom/Development/fuse-fuse/doc' make2: Entering directory `/home/tom/Development/fuse-fuse/doc' make2: Nothing to be done for `install-exec-am'. /bin/mkdir -p '/usr/local/share/man/man1' /usr/bin/install -c -m 644 fusermount.1 '/usr/local/share/man/man1' /bin/mkdir -p '/usr/local/share/man/man8' /usr/bin/install -c -m 644 mount.fuse.8 '/usr/local/share/man/man8' make2: Leaving directory `/home/tom/Development/fuse-fuse/doc' make1: Leaving directory `/home/tom/Development/fuse-fuse/doc' make1: Entering directory `/home/tom/Development/fuse-fuse' make2: Entering directory `/home/tom/Development/fuse-fuse' make2: Nothing to be done for `install-exec-am'. /bin/mkdir -p '/usr/local/lib/pkgconfig' /usr/bin/install -c -m 644 fuse3.pc '/usr/local/lib/pkgconfig' make2: Leaving directory `/home/tom/Development/fuse-fuse' make1: Leaving directory `/home/tom/Development/fuse-fuse' Riförènses See also *PUFFS, a similar framework with FUSE compatibility *9P (protocol) *Installable File System *Dokan Library FUSE Windows compatibility External links * *Crossmeta FUSE Port of FUSE to Windows *Develop your own filesystem with FUSE by Sumit Singh *List of FUSE filesystems *Documentation/filesystems/fuse.txt documentation in Linux source tree *a FUSE-like system for Windows (a FUSE compatibility layer is provided for Cygwin) Category:Free software programmed in C Category:Free special-purpose file systems Category:Linux kernel features Category:Software that uses Meson Category:Unix file system-related software Category:Userspace file systems Category:Free special purpose file systems Category:Linux kernel-supported file systems Category:User space file systems Category:Babyish encyclopedia Category:Linuks päkeij Category:FUSE